<div id="addProductGroupModel" class="modal fade" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog modal-lg">
    <div class="modal-content">
      <div class="modal-body">
        <h3 class="m-t-none m-b "><span>
            <vc:i18n name="添加商品" namespace="addProductGroup"></vc:i18n>
          </span></h3>
        <div class="ibox-content">
          <div>
            <div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label">
                  <vc:i18n name='选择商品' namespace='addProductGroup'></vc:i18n>
                </label>
                <div class="col-sm-3">
                  <select class="custom-select" v-model="addProductGroupInfo.categoryId"
                    @change="_changeAddProductCatalorys()">
                    <option selected disabled value="">{{vc.i18n('请选择分组','addProductGroup')}}</option>
                    <option :value="item.categoryId" v-for="(item,index) in  addProductGroupInfo.productCategorys">
                      {{item.categoryName}}</option>
                  </select>
                </div>
                <div class="col-sm-3">
                  <select class="custom-select" v-model="addProductGroupInfo.productId" @change="_changeAddProduct()">
                    <option selected disabled value="">{{vc.i18n('请选择商品','addProductGroup')}}</option>
                    <option :value="item.productId" v-for="(item,index) in  addProductGroupInfo.products">
                      {{item.prodName}}</option>

                  </select>
                </div>
                <div class="col-sm-3">
                  <select class="custom-select" v-model="addProductGroupInfo.valueId">
                    <option selected disabled value="">{{vc.i18n('请选择规格','addProductGroup')}}</option>
                    <option :value="value.valueId" v-for="(value,index) in  addProductGroupInfo.values">
                      {{ value.specName }}</option>

                  </select>
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='商品简介' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <textarea v-model="addProductGroupInfo.prodDesc"
                    :placeholder="vc.i18n('必填，请填写商品简介','addProductGroup')" class="form-control"></textarea>
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='拼团人数' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <input v-model="addProductGroupInfo.userCount" type="number"
                    :placeholder="vc.i18n('必填，请填写拼团人数','addProductGroup')" class="form-control">
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='拼团金额' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <input v-model="addProductGroupInfo.groupPrice" type="text"
                    :placeholder="vc.i18n('必填，请填写拼团金额','addProductGroup')" class="form-control">
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='状态' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <select class="custom-select" v-model="addProductGroupInfo.state">
                    <option selected disabled value="">{{vc.i18n('必填，请选择状态','addProductGroup')}}</option>
                    <option value="1001">{{vc.i18n('启用','addProductGroup')}}</option>
                    <option value="2002">{{vc.i18n('停用','addProductGroup')}}</option>
                  </select>
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='开始时间' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <input v-model="addProductGroupInfo.startTime" type="text"
                    :placeholder="vc.i18n('必填，请填写开始时间','addProductGroup')"
                    class="form-control addProductGroupStartTime">
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='结束时间' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <input v-model="addProductGroupInfo.endTime" type="text"
                    :placeholder="vc.i18n('必填，请填写结束时间','addProductGroup')" class="form-control addProductGroupEndTime">
                </div>
              </div>
              <div class="form-group row">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='是否返佣' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-10">
                  <select class="custom-select" v-model="addProductGroupInfo.rebateFlag">
                    <option selected disabled value="">{{vc.i18n('必填，请选择是否返佣','addProductGroup')}}</option>
                    <option value="Y">{{vc.i18n('是','addProductGroup')}}</option>
                    <option value="N">{{vc.i18n('否','addProductGroup')}}</option>
                  </select>
                </div>
              </div>
              <div class="form-group row" v-if="addProductGroupInfo.rebateFlag == 'Y'">
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='团长返佣' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <label class="col-sm-2 col-form-label"><span>
                    <vc:i18n name='商用价的' namespace='addProductGroup'></vc:i18n>
                  </span></label>
                <div class="col-sm-2">
                  <input v-model="addProductGroupInfo.rebate" type="number"
                    :placeholder="vc.i18n('几','addProductGroup')" class="form-control">
                </div>
                <label class="col-sm-2 col-form-label">%返佣</label>
              </div>

              <div class="ibox-content">
                <button class="btn btn-primary float-right" type="button" v-on:click="saveProductGroupInfo()"><i
                    class="fa fa-check"></i>&nbsp;

                  <vc:i18n name="保存"></vc:i18n>

                </button>
                <button type="button" class="btn btn-warning float-right" style="margin-right:20px;"
                  data-dismiss="modal">
                  <vc:i18n name="取消"></vc:i18n>
                </button>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</div>